home *** CD-ROM | disk | FTP | other *** search
/ Belgian Amiga Club - ADF Collection / BS1 part 05.zip / BS1 part 5 / SASC_6.0_Disk_7.adf / Source_And_Examples / source / intuitlib.c < prev    next >
Encoding:
C/C++ Source or Header  |  1992-07-30  |  516 b   |  25 lines

  1. void __autoopenfail(char *);
  2.  
  3. #include <proto/exec.h> 
  4. #include <proto/Intuition.h>
  5. struct IntuitionBase *IntuitionBase ;
  6. static void *libbase;
  7. extern long __oslibversion;
  8.  
  9. void _STI_openintuit(void)
  10. {
  11.    IntuitionBase = libbase = 
  12.        (void *)OpenLibrary("intuition.library", __oslibversion);
  13.    if (IntuitionBase == NULL)
  14.       __autoopenfail("intuition.library");
  15. }
  16.  
  17. void _STD_closeintuit(void)
  18. {
  19.    if (libbase)
  20.    {
  21.       CloseLibrary((struct Library *)libbase);
  22.       libbase = IntuitionBase = NULL;
  23.    }
  24. }
  25.